import 'package:example/app/widget/skeleton.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:flutter_base_framework/flutter_base_framework.dart';

import 'article_skeleton.dart';

class HomeShimmerBox extends StatelessWidget {
  const HomeShimmerBox({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Container(
      width: Get.infinity,
      height: Get.infinity,
      child: Column(
        mainAxisAlignment: MainAxisAlignment.start,
        crossAxisAlignment: CrossAxisAlignment.start,
        children: [
          Container(
            color: Colors.white,
            width: Get.infinity,
            height: 160.dp,
            child: Center(
              child: CupertinoActivityIndicator(
                radius: 10.dp,
              ),
            ),
          ),
          Expanded(
            child: SkeletonList(
              builder: (context, index) => ArticleSkeletonItem(),
            ),
          )
        ],
      ),
    );
  }
}
